@extends('home.frame')
<link href="/ho/css/orstyle.css" rel="stylesheet" type="text/css">
@section('content')
    <div class="user-order">

        <!--标题 -->
        <div class="am-cf am-padding">
            <div class="am-fl am-cf"><strong class="am-text-danger am-text-lg">订单管理</strong> / <small>Order</small></div>
        </div>
        <hr/>

        <div class="am-tabs am-tabs-d2 am-margin" data-am-tabs>

            <ul class="am-avg-sm-5 am-tabs-nav am-nav am-nav-tabs">
                <li class="am-active"><a href="#tab1">所有订单</a></li>

                <li><a href="#tab3">已收货</a></li>
                <li><a href="#tab4">待收货</a></li>
                <li><a href="#tab5">待评价</a></li>
            </ul>

            <div class="am-tabs-bd">
                <div class="am-tab-panel am-fade am-in am-active" id="tab1">
                    <div class="order-top">
                        <div class="th th-item">
                            <td class="td-inner">商品</td>
                        </div>
                        <div class="th th-price">
                            <td class="td-inner">单价</td>
                        </div>
                        <div class="th th-number">
                            <td class="td-inner">数量</td>
                        </div>
                        <div class="th th-operation">
                            <td class="td-inner">商品操作</td>
                        </div>
                        <div class="th th-amount">
                            <td class="td-inner">合计</td>
                        </div>
                        <div class="th th-status">
                            <td class="td-inner">交易状态</td>
                        </div>

                    </div>

                    <div class="order-main">
                        <div class="order-list">
                            @foreach($data as $k=>$v)
                                @if($v['status'])
                                    <!--交易成功-->
                                        <div class="order-status5">
                                            <div class="order-title">
                                                <div class="dd-num">订单编号：<a href="javascript:;">{{$v['number']}}</a></div>
                                                <span>成交时间：{{$v['otime']}}</span>
                                                <!--    <em>店铺：小桔灯</em>-->
                                            </div>
                                            <div class="order-content">
                                                <div class="order-left">

                                                    @foreach($v['good'] as $kk=>$vv)
                                                    <ul class="item-list">
                                                        <li class="td td-item">
                                                            <div class="item-pic">
                                                                <a href="#" class="J_MakePoint">
                                                                    <img src="http://lamp187mall.oss-cn-beijing.aliyuncs.com/{{$vv['gphoto']}}" class="itempic J_ItemImg">
                                                                </a>
                                                            </div>
                                                            <div class="item-info">
                                                                <div class="item-basic-info">
                                                                    <a href="#">
                                                                        <p>{{$vv['gname']}}</p>
                                                                        <p class="info-little">特点：{{$vv['gfeature']}}
                                                                           </p>
                                                                    </a>
                                                                </div>
                                                            </div>
                                                        </li>
                                                        <li class="td td-price">
                                                            <div class="item-price">
                                                               {{$vv['gcost']}}
                                                            </div>
                                                        </li>
                                                        <li class="td td-number">
                                                            <div class="item-number">
                                                                <span>×</span>{{$vv['num']}}
                                                            </div>
                                                        </li>
                                                        <li class="td td-operation">
                                                            <div class="item-operation">

                                                            </div>
                                                        </li>
                                                    </ul>
                                                      @endforeach

                                                </div>
                                                <div class="order-right">
                                                    <li class="td td-amount">
                                                        <div class="item-amount">
                                                            合计：{{$v['price']}}
                                                            <p>含运费：<span>10.00</span></p>
                                                        </div>
                                                    </li>
                                                    <div class="move-right">
                                                        <li class="td td-status">
                                                            <div class="item-status">
                                                                <p class="Mystatus">交易成功</p>
                                                                <p class="order-info"><a href="/home/order/show/{{$v['number']}}">订单详情</a></p>
                                                                <p class="order-info"><a href="logistics.html">查看物流</a></p>
                                                            </div>
                                                        </li>
                                                        <li class="td td-change">

                                                        </li>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    @else
                                    <!--交易失败-->
                                        <div class="order-status0">
                                            <div class="order-title">
                                                <div class="dd-num">订单编号：<a href="javascript:;">{{$v['number']}}</a></div>
                                                <span>成交时间：{{$v['otime']}}</span>
                                                <!--    <em>店铺：小桔灯</em>-->
                                            </div>
                                            <div class="order-content">
                                                <div class="order-left">
                                                    @foreach($v['good'] as $kk=>$vv)
                                                    <ul class="item-list">
                                                        <li class="td td-item">
                                                            <div class="item-pic">
                                                                <a href="#" class="J_MakePoint">
                                                                    <img src="http://lamp187mall.oss-cn-beijing.aliyuncs.com/{{$vv['gphoto']}}" class="itempic J_ItemImg">
                                                                </a>
                                                            </div>
                                                            <div class="item-info">
                                                                <div class="item-basic-info">
                                                                    <a href="#">
                                                                        <p>{{$vv['gname']}}</p>
                                                                        <p class="info-little">特点：{{$vv['gfeature']}}
                                                                             </p>
                                                                    </a>
                                                                </div>
                                                            </div>
                                                        </li>
                                                        <li class="td td-price">
                                                            <div class="item-price">
                                                                {{$vv['gcost']}}
                                                            </div>
                                                        </li>
                                                        <li class="td td-number">
                                                            <div class="item-number">
                                                                <span>×</span>{{$vv['num']}}
                                                            </div>
                                                        </li>
                                                        <li class="td td-operation">
                                                            <div class="item-operation">

                                                            </div>
                                                        </li>
                                                    </ul>
                                                        @endforeach


                                                </div>
                                                <div class="order-right">
                                                    <li class="td td-amount">
                                                        <div class="item-amount">
                                                            合计：{{$v['price']}}
                                                            <p>含运费：<span>10.00</span></p>
                                                        </div>
                                                    </li>
                                                    <div class="move-right">
                                                        <li class="td td-status">
                                                            <div class="item-status">

                                                            </div>
                                                        </li>
                                                        <li class="td td-change">

                                                        </li>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    @endif
                                @endforeach







                        </div>

                    </div>

                </div>

                <div class="am-tab-panel am-fade" id="tab3">
                    <div class="order-top">
                        <div class="th th-item">
                            <td class="td-inner">商品</td>
                        </div>
                        <div class="th th-price">
                            <td class="td-inner">单价</td>
                        </div>
                        <div class="th th-number">
                            <td class="td-inner">数量</td>
                        </div>
                        <div class="th th-operation">
                            <td class="td-inner">商品操作</td>
                        </div>
                        <div class="th th-amount">
                            <td class="td-inner">合计</td>
                        </div>
                        <div class="th th-status">
                            <td class="td-inner">交易状态</td>
                        </div>
                        <div class="th th-change">
                            <td class="td-inner">交易操作</td>
                        </div>
                    </div>

                    <div class="order-main">
                        <div class="order-list">
                            @foreach($data1 as $k=>$v)
                            <div class="order-status2">
                                <div class="order-title">
                                    <div class="dd-num">订单编号：<a href="javascript:;">{{$v['number']}}</a></div>
                                    <span>成交时间：{{$v['otime']}}</span>
                                    <!--    <em>店铺：小桔灯</em>-->
                                </div>
                                <div class="order-content">
                                    <div class="order-left">
                                        @foreach($v['good'] as $kk=>$vv)
                                        <ul class="item-list">
                                            <li class="td td-item">
                                                <div class="item-pic">
                                                    <a href="#" class="J_MakePoint">
                                                        <img src="http://lamp187mall.oss-cn-beijing.aliyuncs.com/{{$vv['gphoto']}}" class="itempic J_ItemImg">
                                                    </a>
                                                </div>
                                                <div class="item-info">
                                                    <div class="item-basic-info">
                                                        <a href="#">
                                                            <p>{{$vv['gname']}}</p>
                                                            <p class="info-little">特点：{{$vv['gfeature']}}
                                                            </p>
                                                        </a>
                                                    </div>
                                                </div>
                                            </li>
                                            <li class="td td-price">
                                                <div class="item-price">
                                                  {{$vv['gcost']}}
                                                </div>
                                            </li>
                                            <li class="td td-number">
                                                <div class="item-number">
                                                    <span>×</span>{{$vv['gnum']}}
                                                </div>
                                            </li>
                                            <li class="td td-operation">
                                                <div class="item-operation">
                                                    <a href="refund.html">退款</a>
                                                </div>
                                            </li>
                                        </ul>
                                @endforeach
                                    </div>
                                    <div class="order-right">
                                        <li class="td td-amount">
                                            <div class="item-amount">
                                                合计：{{$v['price']}}
                                                <p>含运费：<span>10.00</span></p>
                                            </div>
                                        </li>
                                        <div class="move-right">
                                            <li class="td td-status">
                                                <div class="item-status">
                                                    <p class="Mystatus">买家已付款</p>
                                                    <p class="order-info"><a href="orderinfo.html">订单详情</a></p>
                                                </div>
                                            </li>

                                        </div>
                                    </div>
                                </div>
                            </div>
                                @endforeach
                        </div>
                    </div>
                </div>
                <div class="am-tab-panel am-fade" id="tab4">
                    <div class="order-top">
                        <div class="th th-item">
                            <td class="td-inner">商品</td>
                        </div>
                        <div class="th th-price">
                            <td class="td-inner">单价</td>
                        </div>
                        <div class="th th-number">
                            <td class="td-inner">数量</td>
                        </div>
                        <div class="th th-operation">
                            <td class="td-inner">商品操作</td>
                        </div>
                        <div class="th th-amount">
                            <td class="td-inner">合计</td>
                        </div>
                        <div class="th th-status">
                            <td class="td-inner">交易状态</td>
                        </div>
                        <div class="th th-change">
                            <td class="td-inner">交易操作</td>
                        </div>
                    </div>

                    <div class="order-main">
                        <div class="order-list">
                            @foreach($data0 as $k=>$v)
                            <div class="order-status3">
                                <div class="order-title">
                                    <div class="dd-num">订单编号：<a href="javascript:;">{{$v['number']}}</a></div>
                                    <span>成交时间：{{$v['otime']}}</span>
                                    <!--    <em>店铺：小桔灯</em>-->
                                </div>
                                <div class="order-content">
                                    <div class="order-left">
                                        @foreach($v['good'] as $kk=>$vv)
                                        <ul class="item-list">
                                            <li class="td td-item">
                                                <div class="item-pic">
                                                    <a href="#" class="J_MakePoint">
                                                        <img src="http://lamp187mall.oss-cn-beijing.aliyuncs.com/{{$vv['gphoto']}}" class="itempic J_ItemImg">
                                                    </a>
                                                </div>
                                                <div class="item-info">
                                                    <div class="item-basic-info">
                                                        <a href="#">
                                                            <p>{{$vv['gname']}}</p>
                                                            <p class="info-little">特点：{{$vv['gfeature']}}</p>

                                                        </a>
                                                    </div>
                                                </div>
                                            </li>
                                            <li class="td td-price">
                                                <div class="item-price">
                                                   {{$vv['gcost']}}
                                                </div>
                                            </li>
                                            <li class="td td-number">
                                                <div class="item-number">
                                                    <span>×</span>{{$vv['gnum']}}
                                                </div>
                                            </li>
                                            <li class="td td-operation">
                                                <div class="item-operation">
                                                    <a href="refund.html">退款/退货</a>
                                                </div>
                                            </li>
                                        </ul>
                                            @endforeach



                                    </div>
                                    <div class="order-right">
                                        <li class="td td-amount">
                                            <div class="item-amount">
                                                合计：{{$v['price']}}
                                                <p>含运费：<span>10.00</span></p>
                                            </div>
                                        </li>
                                        <div class="move-right">
                                            <li class="td td-status">
                                                <div class="item-status">
                                                    <p class="Mystatus">卖家已发货</p>
                                                    <p class="order-info"><a href="/home/order/show0/{{$v['number']}}">订单详情</a></p>

                                                </div>
                                            </li>
                                            <li class="td td-change">
                                                <a href="/home/order/ok/{{$v['number']}}">
                                                <div class="am-btn am-btn-danger anniu">
                                                    确认收货</div>
                                                </a>
                                            </li>
                                        </div>
                                    </div>
                                </div>
                            </div>
                                @endforeach
                        </div>
                    </div>
                </div>

                <div class="am-tab-panel am-fade" id="tab5">
                    <div class="order-top">
                        <div class="th th-item">
                            <td class="td-inner">商品</td>
                        </div>
                        <div class="th th-price">
                            <td class="td-inner">单价</td>
                        </div>
                        <div class="th th-number">
                            <td class="td-inner">数量</td>
                        </div>
                        <div class="th th-operation">
                            <td class="td-inner">商品操作</td>
                        </div>
                        <div class="th th-amount">
                            <td class="td-inner">合计</td>
                        </div>
                        <div class="th th-status">
                            <td class="td-inner">交易状态</td>
                        </div>
                        <div class="th th-change">
                            <td class="td-inner">交易操作</td>
                        </div>
                    </div>

                    <div class="order-main">
                        <div class="order-list">
                            @foreach($data00 as $k=>$v)
                            <!--不同状态的订单	-->
                            <div class="order-status4">
                                <div class="order-title">
                                    <div class="dd-num">订单编号：<a href="javascript:;">{{$v['number']}}</a></div>
                                    <span>成交时间：{{$v['otime']}}</span>

                                </div>
                                <div class="order-content">
                                    <div class="order-left">
                                        @foreach($v['good'] as $kk=>$vv)
                                        <ul class="item-list">
                                            <li class="td td-item">
                                                <div class="item-pic">
                                                    <a href="#" class="J_MakePoint">
                                                        <img src="http://lamp187mall.oss-cn-beijing.aliyuncs.com/{{$vv['gphoto']}}" class="itempic J_ItemImg">
                                                    </a>
                                                </div>
                                                <div class="item-info">
                                                    <div class="item-basic-info">
                                                        <a href="#">
                                                            <p>{{$vv['gname']}}</p>
                                                            <p class="info-little">特点：{{$vv['gfeature']}}
                                                                </p>
                                                        </a>
                                                    </div>
                                                </div>
                                            </li>
                                            <li class="td td-price">
                                                <div class="item-price">
                                                    {{$vv['gcost']}}
                                                </div>
                                            </li>
                                            <li class="td td-number">
                                                <div class="item-number">
                                                    <span>×</span>{{$vv['gnum']}}
                                                </div>
                                            </li>
                                            <li class="td td-operation">
                                                <div class="item-operation">
                                                    <a href="refund.html">退款/退货</a>
                                                </div>
                                            </li>
                                            <li class="td td-change" style="margin-top:10px;margin-left:190px">
                                                <a href="/home/comment/add/{{$vv['gid']}}" >
                                                    <div class="am-btn am-btn-danger anniu" style="margin-top:30px;margin-right:10px;">
                                                        评价商品</div>
                                                </a>
                                            </li>
                                        </ul>
@endforeach
                                    </div>
                                    <div class="order-right" style="width:170px;margin-right:120px;">
                                        <li class="td td-amount">
                                            <div class="item-amount">
                                                合计：{{$v['price']}}
                                                <p>含运费：<span>10.00</span></p>
                                            </div>
                                        </li>
                                        <div class="move-right">
                                            <li class="td td-status">
                                                <div class="item-status">
                                                    <p class="Mystatus">交易成功</p>
                                                    <p class="order-info"><a href="orderinfo.html">订单详情</a></p>
                                                    <p class="order-info"><a href="logistics.html">查看物流</a></p>
                                                </div>
                                            </li>



                                            {{--<li class="td td-change">--}}
                                                {{--<a href="/home/comment/add">--}}
                                                    {{--<div class="am-btn am-btn-danger anniu">--}}
                                                        {{--评价商品</div>--}}
                                                {{--</a>--}}
                                            {{--</li>--}}

                                                {{--<br>--}}


                                        </div>
                                    </div>
                                </div>
                            </div>
@endforeach




                        </div>

                    </div>

                </div>
            </div>

        </div>
    </div>


    @endsection